package rmi;

import java.rmi.NotBoundException;
import java.rmi.RemoteException;
import java.rmi.registry.LocateRegistry;
import java.rmi.registry.Registry;

import bean.User;

public class ClientRmi {

	public static void main(String [] args){
		
		int port = 54000;
		try {
			Registry registry = LocateRegistry.getRegistry(port);
			ServeurRmiInterface serveur = (ServeurRmiInterface) registry.lookup("ServeurRMI");
			User test = new User();
			test.setLogin("maboul");
			test.setPassword("bwaah1337");
			serveur.isLog(test);
		} catch (RemoteException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (NotBoundException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
	}
	
	
}
